package cn.exrick.xboot.base.entity

import cn.exrick.xboot.core.base.XbootBaseEntity
import cn.exrick.xboot.core.base.XbootBaseEntityKt
import cn.exrick.xboot.core.common.utils.SnowFlakeUtil
import com.baomidou.mybatisplus.annotation.TableId
import com.baomidou.mybatisplus.annotation.TableName
import io.swagger.annotations.ApiModel
import io.swagger.annotations.ApiModelProperty
import org.hibernate.annotations.DynamicInsert
import org.hibernate.annotations.DynamicUpdate
import javax.persistence.Column
import javax.persistence.Entity
import javax.persistence.Id
import javax.persistence.Table

/**
 * @author Fei
 */
@Entity
@DynamicInsert
@DynamicUpdate
@Table(name = "en_job_enterprise")
@TableName("en_job_enterprise")
@ApiModel(value = "就职企业")
data class JobEnterprise(

        @ApiModelProperty("公司名称")
        var companyName: String? = null,

        @ApiModelProperty("企业id")
        var enterpriseId: String? = null,

        @ApiModelProperty("职位名称")
        var jobName: String? = null,

        @ApiModelProperty("部门名称")
        var departmentName: String? = null,

        @ApiModelProperty("行业名称")
        var businessName: String? = null,

        @ApiModelProperty("工作时间")
        var jobTime: String? = null,

        @ApiModelProperty("工作内容")
        @Column(length = 1000)
        var jobContent: String? = null

)  : XbootBaseEntityKt() {

    @Id
    @TableId
    override var id: String = SnowFlakeUtil.nextId().toString()


    companion object {
        const val serialVersionUID = 1L
    }
}